package com.rockwell.sniffyhunter.utils;

import com.rockwell.sniffyhunter.model.StatefulRobot;

public enum RobotState implements IStateMachine {
	START {
		@Override
		public
		IStateMachine doAction(IStateObject stateObject) {
			System.out.println("RobotState> Initialize as START. Do any initialize things here");
			return MOVE_TO_NEXT_ZONE;
		}
	},
	SNIFF {
		@Override
		public
		IStateMachine doAction(IStateObject stateObject) {
			System.out.println("RobotState> Do Sniff State actions");
			return ((StatefulRobot)stateObject).Sniff();
		}
	},
	MOVE_TO_NEXT_ZONE {
		@Override
		public
		IStateMachine doAction(IStateObject stateObject) {
			System.out.println("RobotState> Do Move to Next Zone actions");
			return ((StatefulRobot)stateObject).MoveToNextZone();
		}
	},
	PICK_TREASURE {
		@Override
		public
		IStateMachine doAction(IStateObject stateObject) {
			System.out.println("RobotState> Do Pick treasure State actions");
			return ((StatefulRobot)stateObject).PickTreasure();
		}
	},
	UNLOAD {
		@Override
		public
		IStateMachine doAction(IStateObject stateObject) {
			System.out.println("RobotState> Do Unload State actions");
			return ((StatefulRobot)stateObject).UnloadTreasure();
		}
	},
	DONE{
		@Override
		public IStateMachine doAction(IStateObject stateObject) {
			System.out.println("RobotState> Perform Done actions");
			return START;
		}
	};
}
